.class Lcom/waiqin365/lightapp/order/am;
.super Ljava/lang/Object;

# interfaces
.implements Landroid/widget/AdapterView$OnItemClickListener;


# instance fields
.field final synthetic a:Lcom/waiqin365/lightapp/order/OrderListActivity;


# direct methods
.method constructor <init>(Lcom/waiqin365/lightapp/order/OrderListActivity;)V
    .locals 0

    iput-object p1, p0, Lcom/waiqin365/lightapp/order/am;->a:Lcom/waiqin365/lightapp/order/OrderListActivity;

    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    return-void
.end method


# virtual methods
.method public onItemClick(Landroid/widget/AdapterView;Landroid/view/View;IJ)V
    .locals 4

    iget-object v0, p0, Lcom/waiqin365/lightapp/order/am;->a:Lcom/waiqin365/lightapp/order/OrderListActivity;

    invoke-static {v0}, Lcom/waiqin365/lightapp/order/OrderListActivity;->b(Lcom/waiqin365/lightapp/order/OrderListActivity;)Ljava/util/List;

    move-result-object v0

    iget-object v1, p0, Lcom/waiqin365/lightapp/order/am;->a:Lcom/waiqin365/lightapp/order/OrderListActivity;

    invoke-static {v1}, Lcom/waiqin365/lightapp/order/OrderListActivity;->a(Lcom/waiqin365/lightapp/order/OrderListActivity;)Lcom/waiqin365/lightapp/dailyreport/view/CustomListview;

    move-result-object v1

    invoke-virtual {v1}, Lcom/waiqin365/lightapp/dailyreport/view/CustomListview;->getHeaderViewsCount()I

    move-result v1

    sub-int v1, p3, v1

    invoke-interface {v0, v1}, Ljava/util/List;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/waiqin365/lightapp/order/c/a;

    const-string/jumbo v1, "0"

    iget-object v2, v0, Lcom/waiqin365/lightapp/order/c/a;->p:Ljava/lang/String;

    invoke-virtual {v1, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v1

    if-eqz v1, :cond_0

    iget-object v1, p0, Lcom/waiqin365/lightapp/order/am;->a:Lcom/waiqin365/lightapp/order/OrderListActivity;

    invoke-static {v1}, Lcom/waiqin365/lightapp/order/OrderListActivity;->c(Lcom/waiqin365/lightapp/order/OrderListActivity;)Landroid/content/Context;

    move-result-object v1

    invoke-static {v1}, Lcom/waiqin365/lightapp/order/d/a;->a(Landroid/content/Context;)Lcom/waiqin365/lightapp/order/d/a;

    move-result-object v1

    invoke-virtual {v1}, Lcom/waiqin365/lightapp/order/d/a;->b()Z

    move-result v1

    if-eqz v1, :cond_0

    iget-object v0, p0, Lcom/waiqin365/lightapp/order/am;->a:Lcom/waiqin365/lightapp/order/OrderListActivity;

    iget-object v1, p0, Lcom/waiqin365/lightapp/order/am;->a:Lcom/waiqin365/lightapp/order/OrderListActivity;

    invoke-static {v1}, Lcom/waiqin365/lightapp/order/OrderListActivity;->a(Lcom/waiqin365/lightapp/order/OrderListActivity;)Lcom/waiqin365/lightapp/dailyreport/view/CustomListview;

    move-result-object v1

    invoke-virtual {v1}, Lcom/waiqin365/lightapp/dailyreport/view/CustomListview;->getHeaderViewsCount()I

    move-result v1

    sub-int v1, p3, v1

    invoke-static {v0, v1}, Lcom/waiqin365/lightapp/order/OrderListActivity;->a(Lcom/waiqin365/lightapp/order/OrderListActivity;I)V

    :goto_0
    return-void

    :cond_0
    new-instance v1, Landroid/content/Intent;

    iget-object v2, p0, Lcom/waiqin365/lightapp/order/am;->a:Lcom/waiqin365/lightapp/order/OrderListActivity;

    const-class v3, Lcom/waiqin365/lightapp/order/OrderDetailActivity;

    invoke-direct {v1, v2, v3}, Landroid/content/Intent;-><init>(Landroid/content/Context;Ljava/lang/Class;)V

    const-string/jumbo v2, "orderId"

    iget-object v3, v0, Lcom/waiqin365/lightapp/order/c/a;->a:Ljava/lang/String;

    invoke-virtual {v1, v2, v3}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    const-string/jumbo v2, "orderNo"

    iget-object v0, v0, Lcom/waiqin365/lightapp/order/c/a;->c:Ljava/lang/String;

    invoke-virtual {v1, v2, v0}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    iget-object v0, p0, Lcom/waiqin365/lightapp/order/am;->a:Lcom/waiqin365/lightapp/order/OrderListActivity;

    invoke-virtual {v0, v1}, Lcom/waiqin365/lightapp/order/OrderListActivity;->startActivity(Landroid/content/Intent;)V

    iget-object v0, p0, Lcom/waiqin365/lightapp/order/am;->a:Lcom/waiqin365/lightapp/order/OrderListActivity;

    const v1, 0x7f040022

    const v2, 0x7f040021

    invoke-virtual {v0, v1, v2}, Lcom/waiqin365/lightapp/order/OrderListActivity;->overridePendingTransition(II)V

    goto :goto_0
.end method
